package com.softeem.math;

/**
 * 应用:
 */
public class Math_02 {
    public static void main(String[] args) {
        double a = System.currentTimeMillis();
        for (int i = 2; i < 1000000; i++) {
            boolean f = true;
            for (int j = 2; j < Math.sqrt(i); j++) {
                if(i%j==0){
                    f = false;
                }
            }
            if(f){
                System.out.println(i);
            }
        }
        double b = System.currentTimeMillis();
        System.out.println(b-a);
    }
}
